home *** CD-ROM | disk | FTP | other *** search
/ Aminet 41 / Aminet 41 (2001)(Schatztruhe)[!][Feb 2001].iso / Aminet / comm / tcp / netinfo.lha / NetInfo_28 / Install_NetInfo < prev    next >
Text File  |  1999-11-11  |  32KB  |  749 lines

  1. ;******************************************************************************
  2. ;      _   __         __   ______                             ______ ______
  3. ;     / \ / /       _/ /_ /_  __/                            /_  __//_  __/
  4. ;    /   \ /______ /  __/  / /  ______ ______ ______          / /    / /
  5. ;   / /\  // ____/ / /    / /  / __  // ____// __  /______   / /    / /
  6. ;  / / / // __/_  / /_ __/ /_ / / / // __/  / /_/ //_____/__/ /_ __/ /_
  7. ; /_/ /_//_____/ /___//_____//_/ /_//_/    /_____/       /_____//_____/
  8. ;
  9. ; $VER: NetInfo-II_Installer 0.65 (November-11-1999) 
  10. ; NetInfo by Oliver Wagner ©1996-1999
  11. ; Installer by Robert C. Reiswig ©1997, 1998, 1999
  12. ;
  13. ; If you wish to use any part of this installer you must ask. May not be 
  14. ; integrated/placed into any other package. You may NOT change this in an way!
  15. ; Changes, suggestions or problems: netinfo-II@vgr.com or rob@vapor.com
  16. ;******************************************************************************
  17.  
  18. ; NetInfo-II name 
  19.  
  20. ;*** System Stuff ***
  21. (set cpu (database "cpu"))  (set vblank (database "vblank"))
  22. (set graphmem (database "graphics-mem")) (set totmem (database "total-mem"))
  23. (set osver (/ (getversion "LIBS:version.library") 65536))
  24. (if (= vblank "60") ((set blank "NTSC")) ((set blank "PAL")))
  25. (set fastmem (- totmem graphmem))
  26.  
  27. (if (= osver 37) (set workbench "2.0")) (if (= osver 38) (set workbench "2.1"))
  28. (if (= osver 39) (set workbench "3.0")) (if (= osver 40) (set workbench "3.1"))
  29. (if (= osver 41) (set workbench "3.2"))
  30.  
  31. (set cpu (database "cpu"))
  32. (if (= cpu 68000) (set #cpu 0)) (if (= cpu 68010) (set #cpu 1))
  33. (if (= cpu 68020) (set #cpu 2)) (if (= cpu 68030) (set #cpu 3))
  34. (if (= cpu 68040) (set #cpu 4)) 
  35. (if (> (exists ("sys:libs/68060.library")) 0) (set #cpu 5) )
  36.  
  37. (set vernum1 (getversion "NetInfo")) (set ver1 (/ vernum1 65536))
  38.  
  39. (set rev1 (- vernum1 (* ver1 65536) ) ) (set NetInfover (cat ver1 "." rev1))
  40.  
  41. (if (> (exists ("env:Language")) 0) (set lanfound (getenv "Language")) )
  42. (set lan 0)
  43.  
  44. (if (= "english"    lanfound) (set lan 0))  (if (= "deutsch"    lanfound) (set lan 1))
  45. (set #English    "English")  (set #Deutsch    "Deutsch")
  46.  
  47. (set mfound 0) (set newicon1 1) 
  48. (set keeper 1) (set firsttime 0)
  49.  
  50. ;********************************************************************
  51. ; English Strings
  52. ;********************************************************************
  53. (set #about (cat "\n\n\n\nWelcome to NetInfo-II " NetInfover "\n\n\nCopyright ©1996-1999 by Oliver Wagner\n") )
  54. (set #installup " Install or Update NetInfo-II")
  55. (set #clearcache " Clear Cache Directory")
  56. (set #task "\nWhat would you like to do?\n")
  57. (set #whereNetInfo "Where do you wish to install NetInfo-II. The directory 'NetInfo-II' will be created if it is not there. If a copy of NetInfo-II is found it will be backed up.")
  58. (set muiver "No Version Installed")
  59. (set #newermui "\nNetInfo-II needs version 3.8 or higher of MUI installed to work correctly.\n\nNow would be a good time to Upgrade!\n\nYou can find mui38usr.lha on Aminet in util/libs\n\nIt looks like you have: \n\n")
  60. (set #nomuiarc "\nThe installer could not find the MUI dir in the archive. Because of this the MUI Classes used by NetInfo-II were not installed.\n\n If you are Updating NetInfo-II then this is not a problem. If it is your first time installing NetInfo-II you will need to get an archive with these files.")
  61. (set #updatingmuic "\nUpdating the MUI Classes if needed.\n\n(#?.mcc & #?.mcp)")
  62. (set #nompc "\nThe .MCC files for NetInfo-II can not be installed to 'mui:libs/mui'")
  63. (set #need-os "\n\nNetInfo-II needs version 3.0 or higher of the Amiga OS installed to work correctly.\n\n It looks like you have: \n\n")
  64. (set #000used "\n\nThe 68000 version will be installed.") 
  65. (set #nompc "\nThe .MPC files for NetInfo-II can not be installed to 'mui:libs/mui'")
  66. (set #noreg1 "\nThe installer could not find 'S:NetInfo-II.Key' or '")
  67. (set #noreg2 "' on your system. It also does not seem to be in the archive you are installing NetInfo-II from. You may need to get the archive again.\n\nThe installer will now run the Registration Utility, 'Registrationutility'.")   
  68. (set #filethere1 "\n\nThe installer has found NetInfo-II version ")
  69. (set #filethere2 " at ")
  70. (set #filethere3 "\n\nThe file will be renamed to ")
  71. (set #filethere4 " and it will then be moved to ")
  72. (set #backuptoXXX "Back-UP to file named 'NetInfo-II.")
  73. (set #copyover "Copy Over Old Version")
  74. (set #oktodelete1 "\nIs it ok to delete the older NetInfo-II binary so that the NetInfo-II Directory can be made?\n")
  75. (set #oktodelete2 "\nIs it ok to delete the older _renamed_ NetInfo-II binary so that the NetInfo-II Directory can be made?\n")
  76. (set #NetInfofound "\nThe Installer has found a copy of NetInfo-II already installed. What do you want to do?\n")
  77. (set #no030found "\n\nThe 68030+FPU Version of NetInfo-II, V030, was not found in this archive this is why the 68000 version was installed.")
  78. (set #newicon "\nDo you wish to copy over The NetInfo-II Icon from the archive? If you have any ToolTypes already set you should select no.\n")
  79. (set #nonewicon  "No  - ToolTypes already set.")
  80. (set #yesnewicon "Yes - Copy over Icon.")
  81. (set #yesnewicon "Yes - Copy over Icon.")
  82. (set #whatcat "\nSelect the NetInfo-II Language catalog you wish to install.\n")
  83. (set #wherecat "\nWhere do you wish to install the NetInfo-II Language Catalog? Default is ")
  84. (set #catnofind "Can not find this catalog in this NetInfo-II archive. You may need to get a newer archive.")
  85. (set #whattools "\nWhat Tools would you like to install? They will be placed in: ")
  86. (set #updatingmuic "\nUpdating the MUI Classes if needed.\n\n(#?.mcc & #?.mcp)")
  87. (set #nomuiarc "\nThe installer could not find the MUI dir in the archive. Because of this the MUI Classes used by NetInfo-II were not installed.\n\n If you are Updating NetInfo-II then this is not a problem. If it is your first time installing NetInfo-II you will need to get an archive with these files.")
  88. (set #whatdocs "\nWhat NetInfo-II documentation would you like to install?\n")
  89. (set #wheredocs "Where would you like the NetInfo-II documentation you selected to be installed?")
  90. (set #byebye (cat "\nNetInfo-II Install Complete!\n\n" ))
  91.  
  92. (set #askcpu "\nWhat version of NetInfo-II would you like to install?\n")
  93. (set #noregdir "\nThe Registration directory was not found. This means that the archive has been altered or is bad. Please get another copy of the NetInfo-II Archive.\n\nOR\n\nThe Keyfile is missing. Please contact your REG site.")
  94. (set #updatesetpatch "\nThe installer looked for 'c:setpatch' and did not find it or you have a version lower then 40.16. NetInfo-II needs version 40.16 to work correctly. You wany want to upgrade soon. (NOTE: if you keep 'setpatch' in a different place than 'c:' and its 40.16 or higher then this message is void.)")
  95. (set #updateinstaller "\nJust to let you know ESCOM AG has released a new version of the installer program.\n\n\nVersion 43.3 can be found on Aminet in:\n\n/util/misc/Installer-43_3.lha\n\n\nYou might want to upgrade soon, if you can.")
  96.  
  97. (set #whatcat "\nSelect the NetInfo-II Language catalog you wish to install.\n")
  98. (set #wherecat "\nWhere do you wish to install the NetInfo-II Language Catalog? Default is ")
  99. (set #catnofind "Can not find this catalog in this NetInfo-II archive. You may need to get the complete archive from the support site.")
  100.  
  101. (set #wantbuttons "\nThe installer has found that the directory 'Images' exist. Do you still wish to install the default Images? If you have created your own you should select 'No'.\n")
  102. (set #yesbutton "Yes - Copy default images over")
  103. (set #nobuttons "No - Use currently installed images")
  104.  
  105. (set #wantflags "\nThe installer has found that the directory 'Images/Flags' exist. Do you still wish to install the default Flag images? If you have created your own you should select 'No'.\n")
  106. (set #yesflags "Yes - Copy default Flag images over")
  107. (set #noflags "No - Use currently installed Flag images")
  108.  
  109. (set #updatedlibs "\nInstall/Update the Vapor Libraries?\n* = Must be installed to work correctly\n(Click 'Help' for more info on the libs.)\n")
  110. (set #lib1 " Update library (*)")
  111. (set #lib2 " Toolkit library (*)")
  112. (set #lib3 " Registration library")
  113. (set #libhelp1 "vapor_update.library:\nIf installed every Vapor app will automagically check for updates by querying the Vapor server via Internet. You will be informed and offered automatic downloading if there is an update.")
  114. (set #libhelp2 "\n\nvapor_toolkit.library (* Must be installed):\nContains support functions which are used by most Vapor applications and thus can be shared to reduce individual application code size. ie: Async I/O library, crytographically strong random number generator, math support.")
  115. (set #libhelp3 "\n\nvapor_registration.library (* Must be installed):\nContains the core code for the registration utility\n")
  116. (set #wherelibs "Where do you wish to place the Vapor lib(s), 'Libs:' is default.")
  117. (set #flushing "\n\nTrying to flush old Vapor libraries from memory.")
  118.  
  119. (set #insregstuff " Install Register information")
  120. (set #insregstuffno " Don't Install Register information")
  121. (set #installerreg "\nThe installer did not find an NetInfo2 key in the usual places. Do you wish to install the Register information?\n") 
  122.  
  123. (set #libdiff "\nThe installer found one of the Vapor libraries in 'LIBS:' to be a different version than a resident Vapor library (loaded in memory).")
  124. (set #rebootnote1 "\n\nNOTE: If you currently have a Vapor program running now it might have one of the Vapor libraries open. This may prevent the next Vapor application, that may need a newer library from this archive, from working. The installer has already tried to flush the old libraries. If this did not work you may need to reboot.")
  125. (set #rebootnote  "\n\nNOTE: It is strongly recommended that you reboot, after the installer is finished, to ensure that all updated libraries have been flushed. The libraries may be held open by VaporWare applications or MUI custom classes which are currently running.")
  126.  
  127.  
  128. ;********************************************************************
  129. ; Check Last ENV
  130. ;********************************************************************
  131. (if (> (exists "env:Vapor/NetInfo2_LASTUSEDDIR") 0) 
  132.  (
  133.   (set lastdir (getenv "Vapor/NetInfo2_LASTUSEDDIR"))
  134.   (set lastdirlen (strlen lastdir))
  135.   (set tricklen (+ 1 (strlen (fileonly lastdir))))
  136.   (set lastdir (substr lastdir 0 (- lastdirlen tricklen) ) )
  137.   (if (= 0 (exists lastdir (noreq))) (set lastdir (cat lastdir ":"))) 
  138.  )
  139.  (set lastdir 0)
  140. )
  141.  
  142.  
  143. ;********************************************************************
  144. ; German Strings
  145. ;********************************************************************
  146. (if (= lan 1) (set OlliShareSomePizza TRUE) )
  147.  
  148. ;********************************************************************
  149. ; Hello
  150. ;********************************************************************
  151. (message #about)
  152. (welcome) 
  153.  
  154. ;********************************************************************
  155. ; Checks for MUI & OS versions
  156. ;********************************************************************
  157. (set ver 0)
  158. (if (<> (getassign "mui") "")
  159. (
  160.   (if (exists "mui:mui") 
  161.    (
  162.     (set vernum (getversion "mui:mui") )
  163.     (set ver (/ vernum 65536)) (set rev (- vernum (* ver 65536) ) )
  164.    )
  165.   
  166.    (
  167.     (if (exists "sys:prefs/mui") 
  168.      (
  169.        (set vernum (getversion "sys:prefs/mui") )
  170.        (set ver (/ vernum 65536)) (set rev (- vernum (* ver 65536) ) )
  171.      )
  172.     )
  173.    )
  174.   )
  175. )
  176. )
  177.  
  178. (if (= ver 7) (set muiver "2.0") )   (if (= ver 8) (set muiver "2.1") )
  179. (if (= ver 9) (set muiver "2.2") )   (if (= ver 10) (set muiver "2.3") )
  180. (if (= ver 11) (set muiver "3.0") )  (if (= ver 12) (set muiver "3.1") )
  181. (if (= ver 13) (set muiver "3.2") )  (if (= ver 14) (set muiver "3.3") )
  182. (if (= ver 15) (set muiver "3.4") )  (if (= ver 16) (set muiver "3.5") )
  183. (if (= ver 17) (set muiver "3.6") )  (if (= ver 18) (set muiver "3.7") )
  184. (if (= ver 19) (set muiver "3.8") )  (if (= ver 20) (set muiver "3.9") )
  185.  
  186. (if (< ver 19)   ( (message (cat #newermui muiver))   (set cpuPick 0) ))
  187. (if (< osver 37) ( (message (cat #need-os workbench)) (set cpuPick 0) ))
  188.  
  189. ;********************************************************************
  190. ; Ask where to put NetInfo-II & Make dir if needed
  191. ;********************************************************************
  192. (set Package (getassign "AmiTCP") )
  193. (if (= Package "") (set Package (getassign "Inet")) )
  194. (if (<> lastdir 0) (set Package lastdir))
  195.  
  196. (set NetInfodir  (askdir (prompt #whereNetInfo)
  197.                 (help   #whereNetInfo)
  198.                      (default Package)
  199.                )  
  200. )
  201.  
  202. (set where NetInfodir)
  203.  
  204. ;********************************************************************
  205. ; Check to see if NetInfo is already there, if so ask to backup
  206. ;********************************************************************
  207. (if (= 1 (exists (tackon where "NetInfo") ) ) 
  208.   (
  209.     (set vernum1 (getversion (tackon where "NetInfo") ))
  210.     (set ver1 (/ vernum1 65536)) (set rev1 (- vernum1 (* ver1 65536) ) )
  211.     (set NetInfo_old (cat ver1 "." rev1))
  212.  
  213.     (message (cat #filethere1 ver1 "." rev1 #filethere2 where #filethere3 
  214.                   (cat "NetInfo" NetInfo_old) #filethere4 (tackon NetInfodir "NetInfo") )
  215.     )
  216.  
  217.     (copyfiles (source (tackon where "NetInfo"))
  218.                (dest where) 
  219.                (infos)
  220.                (newname (cat "NetInfo." NetInfo_old))
  221.     )
  222.     
  223.     (delete (tackon NetInfodir "NetInfo") (prompt #oktodelete1) (help #oktodelete1) (confirm) (infos)) 
  224.  
  225.     (if (< (exists (tackon NetInfodir "NetInfo-II")) 2) (makedir (tackon NetInfodir "NetInfo-II") (infos)) )    
  226.  
  227.     (copyfiles (source (tackon where (cat "NetInfo." NetInfo_old) ))
  228.                        (dest (tackon NetInfodir "NetInfo")) 
  229.                        (infos)
  230.                
  231.     )
  232.  
  233.     (delete (tackon where (cat "NetInfo-II" NetInfo_old)) (prompt #oktodelete2) (help #oktodelete2) (confirm) (infos) ) 
  234.  
  235.     ;(set firsttime 1)
  236.  
  237.   )
  238. )
  239.  
  240. (if (< (exists (tackon NetInfodir "NetInfo-II")) 2) (makedir (tackon NetInfodir "NetInfo-II") (infos)) )
  241.  
  242. ;********************************************************************
  243. ; copy rooticon if there
  244. ;********************************************************************
  245. (set pathI @icon)  (set pathIlen (strlen pathI))
  246. (set Inamelen (fileonly @icon))
  247. (set Inamelen (+ (strlen Inamelen) 1) )
  248. (set pathI (substr pathI 0 (- pathIlen Inamelen) ) )
  249.  
  250. (if (exists (cat pathI ".info"))
  251.   (copyfiles (source (cat pathI ".info")) (dest (tackon "/" where)) (newname "NetInfo-II.info") (optional "nofail") ) 
  252. )
  253.  
  254. (set where (tackon NetInfodir "NetInfo-II"))
  255. (set @default-dest where)
  256.  
  257. ;********************************************************************
  258. ; Check for old & backup
  259. ;********************************************************************
  260. (if (exists (tackon where "NetInfo")) 
  261.   (
  262.       (set vernum1 (getversion (tackon where "NetInfo") ))
  263.       (set ver1 (/ vernum1 65536)) (set rev1 (- vernum1 (* ver1 65536) ) )
  264.       (set NetInfo_old (cat ver1 "." rev1))
  265.  
  266.       (set keeper  (askchoice (choices  (cat #backuptoXXX NetInfo_old "'")  #copyover)
  267.                      (prompt #NetInfofound)
  268.                  (help   #NetInfofound)
  269.                      (default 0)
  270.                )
  271.       )    
  272.  
  273.       (if (= keeper 0)
  274.          (copyfiles (source (tackon where "NetInfo"))
  275.                      (dest where) 
  276.                      (infos)
  277.                      (newname (cat "NetInfo" NetInfo_old))
  278.          )
  279.       )          
  280.  
  281.       (set firsttime 1)
  282.   )
  283. )
  284.  
  285. ;********************************************************************
  286. ; Copy over correct NetInfo-II and Icon if wanted
  287. ;********************************************************************
  288. (copyfiles (source "NetInfo") (dest where) (optional "nofail") )
  289.  
  290. (if (= firsttime 0)  (copyfiles (source "NetInfo.info") (dest where) (optional "nofail") ) )
  291.  
  292. (if (OR (= keeper 1) (= (exists (tackon where "NetInfo.info")) 0))
  293.   (
  294.    (set newicon (askchoice (choices #yesnewicon #nonewicon)
  295.                            (prompt #newicon)
  296.                        (help   #newicon)
  297.                            (default 0)
  298.             )
  299.    )
  300.   
  301.    (if (= newicon 0) 
  302.      (copyfiles (source "NetInfo.info") (dest where)  (optional "nofail") )
  303.    )
  304.   )
  305. )
  306.  
  307. ;********************************************************************
  308. ; copy ButtonImages/#? if there 
  309. ;********************************************************************
  310. (set button 0)
  311.  
  312. (if (> (exists "Images") 0)
  313.  (
  314.   (if (> (exists (tackon where "Images")) 0)
  315.    (
  316.      (set button  (askchoice (choices #yesbutton #nobuttons)            
  317.                              (prompt #wantbuttons)
  318.                          (help   #wantbuttons)
  319.                              (default 1)
  320.                   )
  321.      )
  322.    )
  323.   )
  324.  
  325.   (if (= button 0)
  326.    (
  327.     (if (< (exists (tackon where "Images")) 2) (makedir (tackon where "Images"))  )
  328.     (foreach "Images" "#?"
  329.       (if (< @each-type 0)
  330.        (copyfiles (source (tackon "Images" @each-name)) (dest (tackon where "Images")) (infos) (optional "nofail") ) 
  331.       )
  332.     )
  333.    )
  334.   )
  335.  
  336.  ) 
  337. )
  338.  
  339. ;********************************************************************
  340. ; copy NetInfo.DomainTable 
  341. ;********************************************************************
  342. (copyfiles (source "NetInfo.DomainTable") (dest where) (infos) (optional "nofail") ) 
  343.  
  344. ;********************************************************************
  345. ; copy Images/Flags/#? if there 
  346. ;********************************************************************
  347. (set flags 0)
  348.  
  349. (if (> (exists "Images/Flags") 0)
  350.  (
  351.   (if (> (exists (tackon where "Images/Flags")) 0)
  352.    (
  353.      (set button  (askchoice (choices #yesflags #noflags)            
  354.                              (prompt #wantflags)
  355.                          (help   #wantflags)
  356.                              (default 1)
  357.                   )
  358.      )
  359.    )
  360.   )
  361.  
  362.   (if (= button 0)
  363.    (
  364.     (if (< (exists (tackon where "Images")) 2) (makedir (tackon where "Images"))  )
  365.     (if (exists "Images.info")
  366.       (copyfiles (source "Images.info") (dest where) (optional "nofail") ) 
  367.     )
  368.  
  369.     (if (< (exists (tackon where "Images/Flags")) 2) (makedir (tackon where "Images/Flags"))  )
  370.     (if (exists "Images/Flags.info")
  371.       (copyfiles (source "Images/Flags.info") (dest (tackon where "Images")) (optional "nofail") ) 
  372.     )
  373.  
  374.     (foreach "Images/Flags" "#?"
  375.       (copyfiles (source (tackon "Images/Flags" @each-name)) (dest (tackon where "Images/Flags")) (infos) (optional "nofail") ) 
  376.     )
  377.    )
  378.   )
  379.  
  380.  ) 
  381. )
  382.  
  383. ;********************************************************************
  384. ; Select and copy over NetInfo Catalog
  385. ;********************************************************************
  386. (if (> (exists "catalogs") 0) 
  387. (
  388. (set XX 0) (set lan 0)
  389. (foreach "Catalogs" "#?"
  390.  (
  391.   (set XX (+ XX 1)) 
  392.   (textfile (dest (cat "ENV:i.høld." XX)) (append @each-name) ) 
  393.   (if (= lanfound @each-name) (set lan XX))
  394.  
  395.   (if (= (patmatch "#?.c#?" @each-name) 1) 
  396.      ( (delete (cat "ENV:i.høld." XX)) (set XX (- XX 1))  )
  397.   )
  398.  
  399.  )
  400. )
  401.  
  402. (set l1 "N/A") (set l2 "N/A") (set l3 "N/A") (set l4 "N/A") (set l5 "N/A")
  403. (set l6 "N/A") (set l7 "N/A") (set l8 "N/A") (set l9 "N/A") (set l10 "N/A")
  404. (set l11 "N/A") (set l12 "N/A") (set l13 "N/A") (set l14 "N/A") (set l15 "N/A") 
  405.  
  406. (set l0 "English")
  407. (if (> (exists ("ENV:i.høld.1")) 0)   (set l1 (getenv "ENV:i.høld.1")) ) (if (> (exists ("ENV:i.høld.2")) 0)   (set l2 (getenv "ENV:i.høld.2")) )
  408. (if (> (exists ("ENV:i.høld.3")) 0)   (set l3 (getenv "ENV:i.høld.3")) ) (if (> (exists ("ENV:i.høld.4")) 0)   (set l4 (getenv "ENV:i.høld.4")) )
  409. (if (> (exists ("ENV:i.høld.5")) 0)   (set l5 (getenv "ENV:i.høld.5")) ) (if (> (exists ("ENV:i.høld.6")) 0)   (set l6 (getenv "ENV:i.høld.6")) )
  410. (if (> (exists ("ENV:i.høld.7")) 0)   (set l7 (getenv "ENV:i.høld.7")) ) (if (> (exists ("ENV:i.høld.8")) 0)   (set l8 (getenv "ENV:i.høld.8")) )
  411. (if (> (exists ("ENV:i.høld.9")) 0)   (set l9 (getenv "ENV:i.høld.9")) ) (if (> (exists ("ENV:i.høld.10")) 0) (set l10 (getenv "ENV:i.høld.10")) )
  412. (if (> (exists ("ENV:i.høld.11")) 0) (set l11 (getenv "ENV:i.høld.11")) )(if (> (exists ("ENV:i.høld.12")) 0) (set l12 (getenv "ENV:i.høld.12")) )
  413. (if (> (exists ("ENV:i.høld.12")) 0) (set l13 (getenv "ENV:i.høld.13")) )(if (> (exists ("ENV:i.høld.14")) 0) (set l14 (getenv "ENV:i.høld.14")) )
  414. (if (> (exists ("ENV:i.høld.15")) 0) (set l15 (getenv "ENV:i.høld.15")) )(if (> (exists ("ENV:i.høld.16")) 0) (set l15 (getenv "ENV:i.høld.16")) )
  415. (run "delete env:i.høld.#?")
  416.  
  417. (set catalog (askchoice (choices l0 l1 l2 l3 l4 l5 l6 l7 l8)            
  418.                         (prompt #whatcat)
  419.                     (help   #whatcat)
  420.                         (default lan)
  421.              )
  422. )
  423.  
  424. (if (= catalog 0)  (set #lcat l0))  
  425. (if (= catalog 1)  (set #lcat l1))  (if (= catalog 2)  (set #lcat l2))  (if (= catalog 3)  (set #lcat l3))  
  426. (if (= catalog 4)  (set #lcat l4))  (if (= catalog 5)  (set #lcat l5))  (if (= catalog 5)  (set #lcat l5))
  427. (if (= catalog 6)  (set #lcat l6))  (if (= catalog 7)  (set #lcat l7))  (if (= catalog 8)  (set #lcat l8))  
  428. (if (= catalog 9)  (set #lcat l9))  (if (= catalog 10) (set #lcat l10)) (if (= catalog 11) (set #lcat l11))
  429. (if (= catalog 12) (set #lcat l12)) (if (= catalog 13) (set #lcat l13)) (if (= catalog 14) (set #lcat l14)) 
  430. (if (= catalog 15) (set #lcat l15)) (if (= catalog 16) (set #lcat l16))
  431.  
  432.  
  433. (if (AND (<> catalog 0) (<> #lcat "N/A"))
  434.  (
  435.   (if (> (exists (cat "Catalogs/" #lcat "/NetInfo.catalog")) 0)
  436.     (
  437.         (set wherecat  (askchoice (choices (tackon where (cat "Catalogs/" #lcat)) (cat "Locale:Catalogs/" #lcat) )
  438.                                   (prompt (cat #wherecat (tackon where (cat "Catalogs/" #lcat)) "\n"))
  439.                             (help   #wherecat)
  440.                                (default 0)
  441.                        )  
  442.         )
  443.  
  444.       (if (= wherecat 1)
  445.         (
  446.          (if (< (exists "Locale:") 2) ( (makedir "sys:Locale") (makeassign "Locale" "sys:Locale") ) )
  447.          (if (< (exists "Locale:Catalogs") 2) (makedir "sys:Locale/Catalogs") )
  448.          (if (< (exists (cat "Locale:Catalogs/" #lcat)) 2) (makedir (cat "sys:Locale/Catalogs/" #lcat)) )
  449.          (copylib (source (cat "Catalogs/" #lcat "/NetInfo.catalog")) (dest (cat "sys:Locale/Catalogs/" #lcat)) )
  450.         )
  451.   
  452.         (
  453.          (if (< (exists (tackon where "Catalogs")) 2) (makedir (tackon where "Catalogs")) )
  454.          (if (< (exists (tackon where (cat "Catalogs/" #lcat)) ) 2) (makedir (tackon where (cat "Catalogs/" #lcat)) ) )
  455.          (copylib (source (cat "Catalogs/" #lcat "/NetInfo.catalog")) (dest (tackon where (cat "Catalogs/" #lcat)) ) (optional "nofail") )
  456.         )
  457.       )
  458.  
  459.     )
  460.  
  461.     (message (cat "\nCatalogs/" #lcat "/NetInfo.catalog\n\n" #catnofind))
  462.   )
  463.  
  464.  )
  465. )
  466. ); End if Catalog dir
  467. ); 
  468.  
  469.  
  470. ;********************************************************************
  471. ; Ask and and copy docs if wanted!
  472. ;********************************************************************
  473. (set nodocs 0)
  474.  
  475. (set docs (askoptions (choices " NetInfo.readme")
  476.               (prompt #whatdocs)
  477.                       (help #whatdocs)
  478.                   (default 1)
  479.       )
  480. )
  481.  
  482.  
  483. (if (<> docs 0)
  484.  (
  485.    (set docsdir (askdir (prompt #wheredocs)
  486.                (help   #wheredocs)
  487.                     (default where)
  488.                 )  
  489.    )
  490.  
  491.    (if (IN docs 0)
  492.     (copyfiles (source "netinfo.readme") (dest docsdir) (infos) (optional "nofail") )
  493.    )
  494.  )
  495. )
  496.  
  497. ;********************************************************************
  498. ; Copy over #?.mpc|#?.mcc (Need to be in mui:libs/mui)
  499. ;********************************************************************
  500. (if (<> (getassign "mui") "")
  501. (
  502.   (if (> (exists "mui:libs/mui") 0) 
  503.    (
  504.     (working #updatingmuic)
  505.     (foreach "mui" "#?.mcp"
  506.         (copylib (source (tackon "mui" @each-name)) (dest "mui:libs/mui") (optional "nofail") ) 
  507.     )
  508.     (foreach "mui" "#?.mcc"
  509.         (copylib (source (tackon "mui" @each-name)) (dest "mui:libs/mui") (optional "nofail") ) 
  510.     )
  511.    )
  512.  
  513.    (message (cat #newermui muiver #nompc)) 
  514.   )
  515. )
  516. )
  517.  
  518. ;********************************************************************
  519. ; Copy update Lib if wanted 
  520. ;********************************************************************
  521. (set deflibs 7)
  522. (if (> (exists "libs") 0)
  523.  (
  524.   (set deflibs 0)
  525.   (if (> (exists (tackon "libs" "vapor_update.library")) 0)       (set deflibs (+ deflibs 1)))
  526.   (if (> (exists (tackon "libs" "vapor_toolkit.library")) 0)      (set deflibs (+ deflibs 2)))
  527.   (if (> (exists (tackon "libs" "vapor_registration.library")) 0) (set deflibs (+ deflibs 4)))
  528.  
  529.   (set libPick (askoptions (choices #lib1 #lib2 #lib3)
  530.               (prompt #updatedlibs)
  531.                       (help   (cat #libhelp1 #libhelp2 #libhelp3))
  532.                     (default deflibs)
  533.            )
  534.   )
  535.  
  536.   (if (> libPick 0)
  537.    (
  538.     (set wherelibs (askdir (prompt #wherelibs)
  539.                   (help   #wherelibs)
  540.                        (default "LIBS:")
  541.                    )  
  542.     )
  543.     
  544.     (if (IN libPick 0)
  545.      (if (> (exists (tackon "libs" "vapor_update.library")) 0)
  546.       (copylib (source (tackon "libs" "vapor_update.library")) (dest wherelibs) (optional "nofail"))  
  547.      )
  548.     )
  549.  
  550.     (if (IN libPick 1)
  551.      (if (> (exists (tackon "libs" "vapor_toolkit.library")) 0)
  552.       (copylib (source (tackon "libs" "vapor_toolkit.library")) (dest wherelibs) (optional "nofail"))  
  553.      )
  554.     )
  555.  
  556.     (if (IN libPick 2)
  557.      (if (> (exists (tackon "libs" "vapor_registration.library")) 0)
  558.       (copylib (source (tackon "libs" "vapor_registration.library")) (dest wherelibs) (optional "nofail"))  
  559.      )
  560.     )
  561.  
  562.    (working #flushing) ;(run "avail flush > NIL:") (run "avail flush > NIL:") (run "avail flush > NIL:")
  563.  
  564.    (if (exists "flushlib")
  565.      (run "flushlib QUIET vapor_#?.library CManager.#?")
  566.    )
  567.   
  568.  
  569.    )
  570.  
  571.   )
  572.  )
  573. )
  574.  
  575. ;********************************************************************
  576. ; Check version of libs resident VS in libs: then note reboot
  577. ;********************************************************************
  578. (if (> (exists "libs") 0)
  579.  (
  580.   (set lib_localdir "Libs:")
  581.  
  582.   (procedure checkversion
  583.    (set vernum1 (getversion (tackon lib_localdir ver_checkfile)))
  584.    (set ver1 (/ vernum1 65536)) 
  585.    (set rev1 (- vernum1 (* ver1 65536) ) )
  586.    (set ver_result (cat ver1 "." rev1))
  587.   )
  588.   (procedure checkversionR
  589.    (set vernum1 (getversion (tackon lib_localdir ver_checkfile) (resident)))
  590.    (set ver1 (/ vernum1 65536)) 
  591.    (set rev1 (- vernum1 (* ver1 65536) ) )
  592.    (set ver_result (cat ver1 "." rev1))
  593.   )
  594.  
  595.   (set ver_checkfile "vapor_toolkit.library") (checkversion) (set toolkit_ver ver_result)
  596.   (set ver_checkfile "vapor_update.library") (checkversion) (set update_ver ver_result)
  597.   (set ver_checkfile "vapor_registration.library") (checkversion) (set reg_ver ver_result)
  598.  
  599.   (if (= toolkit_ver "0.0") (set toolkit_ver "None"))
  600.   (if (= update_ver "0.0") (set update_ver "None"))
  601.   (if (= reg_ver "0.0") (set reg_ver "None"))
  602.  
  603.   (set lib_localdir "")
  604.   (set ver_checkfile "vapor_toolkit.library") (checkversionR) (set toolkit_verR ver_result)
  605.   (set ver_checkfile "vapor_update.library") (checkversionR) (set update_verR ver_result)
  606.   (set ver_checkfile "vapor_registration.library") (checkversionR) (set reg_verR ver_result)
  607.  
  608.   (if (= toolkit_verR "0.0") (set toolkit_verR "None"))
  609.   (if (= update_verR "0.0") (set update_verR "None"))
  610.   (if (= reg_verR "0.0") (set reg_verR "None"))
  611.  
  612.  
  613.   (set #verchecklib (cat "Vapor Library Version Check\n------------------------------------\n"
  614.                          "vapor_toolkit.library\nIn 'LIBS:' " toolkit_ver " (In memory: " toolkit_verR ")" 
  615.                          "\n\nvapor_update.library\nIn 'LIBS:' " update_ver " (In memory: " update_verR ")" 
  616.                          "\n\nvapor_registration.library\nIn 'LIBS:' " reg_ver " (In memory: " reg_verR ")"
  617.                     ) 
  618.   )
  619.   
  620.   (set libdiff 0)
  621.   (if (<> toolkit_ver toolkit_verR) (set libdiff 1)) 
  622.   (if (<> update_ver update_verR)   (set libdiff 1))
  623.   (if (<> reg_ver reg_verR)         (set libdiff 1)) 
  624.  
  625.   (if (= libdiff 1)
  626.    (
  627.     (message #verchecklib)
  628.     (message (cat #libdiff #rebootnote))
  629.    )
  630.   )
  631.  
  632.  )
  633. )
  634.  
  635. ;********************************************************************
  636. ; Reg stuff Register-Netinfo
  637. ;********************************************************************
  638. (procedure checkforkey
  639.  (set foundkey 0) 
  640.  (set kc "netinfo-2.key")
  641.  
  642.  (if (exists kc (noreq)) (set foundkey 1) )
  643.  (if (exists (tackon where kc) (noreq)) (set foundkey 1) )
  644.  (if (exists (tackon "s:" kc) (noreq)) (set foundkey 1) )
  645.  (if (exists (tackon "l:" kc) (noreq)) (set foundkey 1) )
  646.  (if (exists (tackon "libs:" kc) (noreq)) (set foundkey 1) )
  647.  (if (exists (tackon "keypath:" kc) (noreq)) (set foundkey 1) )
  648.  (if (exists (tackon "keyfiles:" kc) (noreq)) (set foundkey 1) )
  649.  
  650.  (if (= foundkey 0)
  651.   (set wantkey (askchoice  (choices #insregstuffno #insregstuff)
  652.                        (prompt #installerreg)
  653.                            (help #installerreg)
  654.                        (default 1)
  655.                )
  656.   )
  657.  
  658.   (set wantkey 0)
  659.  )
  660. )
  661.  
  662. (checkforkey)
  663.  
  664. (if (AND (exists "Register-NetInfo") (= wantkey 1))
  665.  (
  666.   (if (< (exists (tackon where "Register-NetInfo")) 2) (makedir (tackon where "Register-NetInfo") (infos)) )    
  667.   (if (exists "Register-Netinfo.info")
  668.     (copyfiles (source "Register-Netinfo.info") (dest where) (optional "nofail") ) 
  669.   )
  670.   (set whereR (tackon where "Register-Netinfo"))
  671.  
  672.  
  673.   (set whatreg  (askchoice (choices "English"  "Deutsch" "Francais" )
  674.                            (prompt "What Registration Files (Language) would you like to install?")
  675.                        (help   "What Registration Files (Language) would you like to install?")
  676.                         (default 0)
  677.                 )  
  678.   )
  679.  
  680.   (if (= whatreg 0) ((set basereg "English")  (set baseregTT "English") ) )
  681.   (if (= whatreg 1) ((set basereg "Deutsch")  (set baseregTT "Deutsch") ) )
  682.   (if (= whatreg 2) ((set basereg "Francais") (set baseregTT "French")  ) )
  683.  
  684.   (if (exists "Register-Netinfo/RegistrationUtility") 
  685.     (copyfiles (source "Register-Netinfo/RegistrationUtility")
  686.                (dest whereR)
  687.                (infos)
  688.     )
  689.   )
  690.  
  691.   ;(if (exists (tackon "Register-Netinfo" (cat "Regtool-" basereg ".info")) )
  692.   ;  (copyfiles (source (tackon "Register-Netinfo" (cat "Regtool-" basereg ".info")) )
  693.   ;             (dest whereR) 
  694.   ;             (newname "RegistrationUtility.info")
  695.   ;  )
  696.   ;)
  697.  
  698.   (if (exists (tackon "Register-Netinfo" (cat "Reg_" basereg ".guide")) ) 
  699.     (copyfiles (source (tackon "Register-Netinfo" (cat "Reg_" basereg ".guide")))
  700.                (dest whereR) 
  701.                (infos)
  702.     )
  703.   )
  704.  
  705.   (if (exists (tackon "Register-Netinfo" (cat "Reg_" basereg ".doc")) )
  706.     (copyfiles (source (tackon "Register-Netinfo" (cat "Reg_" basereg ".doc")))
  707.                (dest whereR) 
  708.                (infos)
  709.     )
  710.   )
  711.  
  712.  
  713.  )
  714. )
  715.  
  716. ;********************************************************************
  717. ; copy keyfile if there 
  718. ;********************************************************************
  719. (if (> (exists kc) 0)
  720.  (copyfiles (source kc) (dest where) (infos) (optional "nofail") ) 
  721. )
  722.  
  723. ;********************************************************************
  724. ; Check on Setpatch 
  725. ;********************************************************************
  726. (set vernum1 (getversion "c:setpatch")) (set ver1 (/ vernum1 65536)) 
  727. (set rev1 (- vernum1 (* ver1 65536) ) ) (set setpatchver (cat ver1 "." rev1))
  728. (set current_setpatch "40.16")
  729. (if (< setpatchVer current_setpatch) (message #updatesetpatch) )
  730.  
  731. ;********************************************************************
  732. ; Check on New installer 
  733. ;********************************************************************
  734. (set InstallerVer 0)
  735. (set vernum1 @installer-version) (set ver1 (/ vernum1 65536)) 
  736. (set rev1 (- vernum1 (* ver1 65536) ) ) (set InstallerVer (cat ver1 "." rev1))
  737. (set current_installer "43.3")
  738. (if (< InstallerVer current_installer) (message #updateinstaller) )
  739.  
  740. ;********************************************************************
  741. ; End Bye 
  742. ;********************************************************************
  743. (if (> (exists ("c:multiview")) 0) (set #mpath "c:") )
  744. (if (> (exists ("sys:Utilities/multiview")) 0) (set #mpath "sys:Utilities") )
  745.  
  746. (run (cat "run " #mpath "/multiview netinfo.readme") )
  747. (exit (quiet) #byebye)
  748.  
  749.